package com.gaoxi.controller;

import com.alibaba.dubbo.config.annotation.Reference;
import com.gaoxi.entity.user.UserEntity;
import com.gaoxi.facade.user.UserService;
import com.gaoxi.req.user.LoginReq;
import com.gaoxi.rsp.Result;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpServletResponse;
import java.util.Map;

/***
 *
 * @author lfl
 * @description
 * @Date 2021/11/13 19:36 
 * @Modified By
 */
@RestController
@RequestMapping("gaoxiTest")
public class UserController {

    @Reference(version = "1.0.0")
    private UserService userService;

    @PostMapping("/login")
    public Result login(String username,String password) {
        // 登录鉴权
        Map<String,Object> paramMap=   userService.testLoginMap(username,password);
        return Result.newSuccessResult(paramMap);
    }

}
